<?php

namespace common\models\ar;

use Yii;

/**
 * This is the model class for table "user_money".
 *
 * @property string $id
 * @property string $userID 外键,用户id
 * @property string $totalMoney 用户的总资金
 * @property string $userDeposit 用户自由资金额度
 * @property string $equip 授信额度
 */
class UserMoney extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'user_money';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['userID'], 'required'],
            [['userID'], 'integer'],
            [['totalMoney', 'userDeposit', 'equip'], 'number'],
            [['userID'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'userID' => 'User ID',
            'totalMoney' => 'Total Money',
            'userDeposit' => 'User Deposit',
            'equip' => 'Equip',
        ];
    }
}
